package com.example.medical.entity.pojo;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import java.io.Serializable;

import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;

/**
 * 
 * @TableName affairs
 */
@TableName(value ="affairs")
@Data
@Builder
@AllArgsConstructor
@NoArgsConstructor
public class Affairs implements Serializable {
    /**
     * 主键
     */
    @TableId(value = "affairs_id", type = IdType.AUTO)
    private Integer affairsId;

    /**
     * 事务分类
0：设备出库
1：设备入库
2：设备转科
3：设备报损
4：设备检测
5：设备维修
6：设备采购
     */
    @TableField(value = "affairs_category")
    private Integer affairsCategory;

    /**
     * 设备名
     */
    @TableField(value = "affairs_device_name")
    private String affairsDeviceName;

    /**
     * 设备编号
     */
    @TableField(value = "affairs_device_number")
    private String affairsDeviceNumber;

    /**
     * 设备型号
     */
    @TableField(value = "affairs_device_model")
    private String affairsDeviceModel;

    /**
     * 设备库存
     */
    @TableField(value = "affairs_device_inventory")
    private Long affairsDeviceInventory;

    /**
     * 设备主键
     */
    @TableField(value = "affairs_device_id")
    @JsonFormat(shape = JsonFormat.Shape.STRING)
    private Long affairsDeviceId;

    /**
     * 设备类型名
     */
    @TableField(value = "affairs_device_type_name")
    private String affairsDeviceTypeName;

    /**
     * 设备类型主键
     */
    @TableField(value = "affairs_device_type_id")
    @JsonFormat(shape = JsonFormat.Shape.STRING)
    private Long affairsDeviceTypeId;

    /**
     * 员工昵称
     */
    @TableField(value = "affairs_user_nick")
    private String affairsUserNick;

    /**
     * 员工头像
     */
    @TableField(value = "affairs_user_img_url")
    private String affairsUserImgUrl;

    /**
     * 员工科室名
     */
    @TableField(value = "affairs_user_division_name")
    private String affairsUserDivisionName;

    /**
     * 员工科室主键
     */
    @TableField(value = "affairs_user_division_id")
    @JsonFormat(shape = JsonFormat.Shape.STRING)
    private Long affairsUserDivisionId;

    /**
     * 员工电话
     */
    @TableField(value = "affairs_user_phone")
    private Long affairsUserPhone;

    /**
     * 员工身份证
     */
    @TableField(value = "affairs_user_number")
    private Long affairsUserNumber;

    /**
     * 员工主键
     */
    @TableField(value = "affairs_user_id")
    @JsonFormat(shape = JsonFormat.Shape.STRING)
    private Long affairsUserId;

    /**
     * 操作数量
     */
    @TableField(value = "affairs_number")
    private Long affairsNumber;

    /**
     * 操作备注
     */
    @TableField(value = "affairs_message")
    private String affairsMessage;

    /**
     * 事务状态
0：员工申请
1：领导提交
2：员工退回
3：事务完结
4：领导拒绝
     */
    @TableField(value = "affairs_type")
    private Integer affairsType;

    /**
     * 事务结果
0：已提交
1：已确定
2：有异常
3：已完成
4：已拒绝
     */
    @TableField(value = "affairs_end")
    private Integer affairsEnd;

    /**
     * 给予的员工昵称
     */
    @TableField(value = "affairs_end_user_nick")
    private String affairsEndUserNick;

    /**
     * 给予的员工头像
     */
    @TableField(value = "affairs_end_user_img_url")
    private String affairsEndUserImgUrl;

    /**
     * 给予的员工科室名
     */
    @TableField(value = "affairs_end_user_division_name")
    private String affairsEndUserDivisionName;

    /**
     * 给予的员工科室主键
     */
    @TableField(value = "affairs_end_user_division_id")
    @JsonFormat(shape = JsonFormat.Shape.STRING)
    private Long affairsEndUserDivisionId;

    /**
     * 给予的员工电话
     */
    @TableField(value = "affairs_end_user_phone")
    private Long affairsEndUserPhone;

    /**
     * 给予的员工身份证
     */
    @TableField(value = "affairs_end_user_number")
    private Long affairsEndUserNumber;

    /**
     * 给予的员工主键
     */
    @TableField(value = "affairs_end_user_id")
    @JsonFormat(shape = JsonFormat.Shape.STRING)
    private Long affairsEndUserId;

    /**
     * 拒绝理由
     */
    @TableField(value = "affairs_memo")
    private String affairsMemo;

    /**
     * 出入库类型：
0：出库
1：入库
     */
    @TableField(value = "affairs_action")
    private Integer affairsAction;

    /**
     * 添加时间
     */
    @TableField(value = "save_time")
    private String saveTime;

    /**
     * 员工邮箱
     */
    @TableField(value = "affairs_user_email")
    private String affairsUserEmail;

    /**
     * 给予的员工邮箱
     */
    @TableField(value = "affairs_end_user_email")
    private String affairsEndUserEmail;

    /**
     * 科室名
     */
    @TableField(value = "affairs_division_name")
    private String affairsDivisionName;

    /**
     * 科室主键
     */
    @TableField(value = "affairs_division_id")
    @JsonFormat(shape = JsonFormat.Shape.STRING)
    private Long affairsDivisionId;

    /**
     * 逻辑删除
     */
    @TableField(value = "is_delete")
    private Integer isDelete;

    @TableField(exist = false)
    private static final long serialVersionUID = 1L;
}